import Vue from 'vue'
import App from './App.vue'
import router from './router'
import store from './store'

import ElementUI from 'element-ui';
import 'element-ui/lib/theme-chalk/index.css';
import topNav from '@/components/topNav.vue'
import buttonNav from '@/components/buttonNav.vue'
Vue.component('top-nav',topNav)
Vue.component('button-nav',buttonNav)
Vue.use(ElementUI);

import axios from 'axios'
axios.defaults.withCredentials = true  //让ajax携带cookie
Vue.prototype.$axios = axios

new Vue({
  router,
  store,
  render: h => h(App)
}).$mount('#app')
